<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>

    <style>
        .WARNING {
            font-weight: bold;
            font-size: 150%;
            margin: 0 1in 0 1in;
            background-color: yellow;
            border: solid red 8px;
            padding: 10px;
            /* 10 pixels on all 4 sides */
        }

        /*
         *   class = "WARNING" 的元素里，面的H1或H2标签的文本，除了蓝色，还应该居中显示
         */

        .WARNING h1,
        .WARNING h2 {
            text-align: center
        }

        /*
         * id = "special" 的元素大写、 居中显示
         */
        #special {
            text-align: center;
            text-transform: uppercase;
        }
    </style>
</head>


<body>

    <h1>Cascading Style Sheets Demo</h1>

    <div class="WARNING">
        <h2>Warning</h2>
        This is a warning!
        Notice how it grabs your attention with its bold text and bright colors.
        Also notice that the heading is centered and in blue italics.
    </div>

    <p id="special">
        This paragraph is centered<br>
        and appears in uppercase letters.<br>
        <span style="text-transform: none">
            Here we explicitly use an inline style to override the uppercase letters.
        </span>
    </p>

</body>

</html>